The phrase "to cook the garlic" means to heat the garlic in a pan or oven until it becomes fragrant and softens its texture.